#pragma once
#include "Main/stdafx.h"
#include "Game/Game/GameDefine.h"

class BJLZhanJiRecordLayer : public cocos2d::Layer
{
public:
	BJLZhanJiRecordLayer(){}
	~BJLZhanJiRecordLayer(){}

public:
	const static int MAX_PLAYER = 10;
public:
	CREATE_FUNC(BJLZhanJiRecordLayer);
	virtual	bool		init();
	virtual void		onEnter();
	virtual void		onExit();
	void				BtnCallBack(Ref* pSender, Widget::TouchEventType touchtype);

	void                showZhanJiRecordLayer();
	void                hideZhanJiRecordLayer();
	
	void                createZhanJiRecord(const int index, const int playerNum, const LONGLONG* playerScore, const int localPlayerIndex);

	void                showPlayerID(int index, int mId);
	void                showPlayerAllScore(int index, int score, const int localPlayerIndex);

	void                clearZhanJiRecord();

private:
	Node*				layoutMain;
	ListView*           _listView;

	Text*               m_TxtID[MAX_PLAYER];
	Text*               m_TxtAllScore[MAX_PLAYER];
};
